import {user} from '../api/passport.js' 
export default {
	checkLogin(fun){
		var token = uni.getStorageSync('token');
		if (token){
			user({token:token}).then(res=>{
				if (res.code==200){
					console.log(res['user'],'success');
					fun(res['user']);
				}
			})
		}else{
			return false;
		}
	}
}